<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateSmsLogTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('sms_log', function (Blueprint $table) {
            $table->increments('id');
            $table->string("mobile",15)->default('')->comment("手机号");
            $table->string("content",200)->default('')->comment("短信内容");
            $table->integer("is_success")->default(0)->comment("是否发送成功 0否 1是");
            $table->string("result",500)->default('')->comment("请求结果");
            $table->char('ip',15)->default('')->comment('ip');
            $table->string("action",50)->default('')->comment('操作');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('sms_log');
    }
}
